﻿using System;
using UnityEngine;

public class RandomPlayAudioClipOnEnable : MonoBehaviour
{
    public AudioSource audioSource;
    public AudioClip[] clips;

    private void OnEnable()
    {
        this.audioSource.clip = this.clips.GetRandomElement<AudioClip>();
        this.audioSource.Play();
    }
}

